import java.util.LinkedList;

public class test {
    public static final String RESET = "\u001B[0m";
    public static final String RED = "\u001B[31m";
    public static final String GREEN = "\u001B[32m";
    public static final String YELLOW = "\u001B[33m";

    public static void logError(String msg) {
        System.out.println(RED + "[ERROR] " + msg + RESET);
    }

    public static void logInfo(String msg) {
        System.out.println(GREEN + "[INFO] " + msg + RESET);
    }

    public static void logWarn(String msg) {
        System.out.println(YELLOW + "[WARN] " + msg + RESET);
    }

    public static void main(String[] args) {
        logInfo("服务启动成功");
        logWarn("内存使用率偏高");
        logError("数据库连接失败");
    }
}
